/* Generates integer IDs at compile time by hashing strings.

    Based on:
    http://www.humus.name/index.php?page=News&ID=296

    @remarks This class exploits two language details to get optimized out of
            the compiled code. Firstly, the use of array references lets the 
            compiler know the string's existence and size. Secondly, the lack
            of the @c explicit keyword allows a string literal to be converted 
            directly to a StringId.
            
    @author Joshua Ols <crunchy.bytes.blog@gmail.com>
 */

#ifndef STATICSTRINGHASH_H
#define STATICSTRINGHASH_H

#ifdef _WIN32
#define DunForceInline __forceinline
#else
#define DunForceInline __attribute__(always_inline)
#endif

DunForceInline unsigned int getStaticStringHash(const char (&str)[2])
{
    return str[0];
} 

DunForceInline unsigned int getStaticStringHash(const char (&str)[3])
{
    unsigned int uiHash = str[0];
    uiHash = (uiHash * 65599u) + str[1];
    return uiHash;
} 

DunForceInline unsigned int getStaticStringHash(const char (&str)[4])
{
    unsigned int uiHash = str[0];
    uiHash = (uiHash * 65599u) + str[1];
    uiHash = (uiHash * 65599u) + str[2];
    return uiHash;
}

DunForceInline unsigned int getStaticStringHash(const char (&str)[5])
{
    unsigned int uiHash = str[0];
    uiHash = (uiHash * 65599u) + str[1];
    uiHash = (uiHash * 65599u) + str[2];
    uiHash = (uiHash * 65599u) + str[3];
    return uiHash;
}

DunForceInline unsigned int getStaticStringHash(const char (&str)[6])
{
    unsigned int uiHash = str[0];
    uiHash = (uiHash * 65599u) + str[1];
    uiHash = (uiHash * 65599u) + str[2];
    uiHash = (uiHash * 65599u) + str[3];
    uiHash = (uiHash * 65599u) + str[4];
    return uiHash;
} 

DunForceInline unsigned int getStaticStringHash(const char (&str)[7])
{
    unsigned int uiHash = str[0];
    uiHash = (uiHash * 65599u) + str[1];
    uiHash = (uiHash * 65599u) + str[2];
    uiHash = (uiHash * 65599u) + str[3];
    uiHash = (uiHash * 65599u) + str[4];
    uiHash = (uiHash * 65599u) + str[5];
    return uiHash;
} 

DunForceInline unsigned int getStaticStringHash(const char (&str)[8])
{
    unsigned int uiHash = str[0];
    uiHash = (uiHash * 65599u) + str[1];
    uiHash = (uiHash * 65599u) + str[2];
    uiHash = (uiHash * 65599u) + str[3];
    uiHash = (uiHash * 65599u) + str[4];
    uiHash = (uiHash * 65599u) + str[5];
    uiHash = (uiHash * 65599u) + str[6];
    return uiHash;
} 

DunForceInline unsigned int getStaticStringHash(const char (&str)[9])
{
    unsigned int uiHash = str[0];
    uiHash = (uiHash * 65599u) + str[1];
    uiHash = (uiHash * 65599u) + str[2];
    uiHash = (uiHash * 65599u) + str[3];
    uiHash = (uiHash * 65599u) + str[4];
    uiHash = (uiHash * 65599u) + str[5];
    uiHash = (uiHash * 65599u) + str[6];
    uiHash = (uiHash * 65599u) + str[7];
    return uiHash;
} 

DunForceInline unsigned int getStaticStringHash(const char (&str)[10])
{
    unsigned int uiHash = str[0];
    uiHash = (uiHash * 65599u) + str[1];
    uiHash = (uiHash * 65599u) + str[2];
    uiHash = (uiHash * 65599u) + str[3];
    uiHash = (uiHash * 65599u) + str[4];
    uiHash = (uiHash * 65599u) + str[5];
    uiHash = (uiHash * 65599u) + str[6];
    uiHash = (uiHash * 65599u) + str[7];
    uiHash = (uiHash * 65599u) + str[8];
    return uiHash;
} 

DunForceInline unsigned int getStaticStringHash(const char (&str)[11])
{
    unsigned int uiHash = str[0];
    uiHash = (uiHash * 65599u) + str[1];
    uiHash = (uiHash * 65599u) + str[2];
    uiHash = (uiHash * 65599u) + str[3];
    uiHash = (uiHash * 65599u) + str[4];
    uiHash = (uiHash * 65599u) + str[5];
    uiHash = (uiHash * 65599u) + str[6];
    uiHash = (uiHash * 65599u) + str[7];
    uiHash = (uiHash * 65599u) + str[8];
    uiHash = (uiHash * 65599u) + str[9];
    return uiHash;
} 

DunForceInline unsigned int getStaticStringHash(const char (&str)[12])
{
    unsigned int uiHash = str[0];
    uiHash = (uiHash * 65599u) + str[1];
    uiHash = (uiHash * 65599u) + str[2];
    uiHash = (uiHash * 65599u) + str[3];
    uiHash = (uiHash * 65599u) + str[4];
    uiHash = (uiHash * 65599u) + str[5];
    uiHash = (uiHash * 65599u) + str[6];
    uiHash = (uiHash * 65599u) + str[7];
    uiHash = (uiHash * 65599u) + str[8];
    uiHash = (uiHash * 65599u) + str[9];
    uiHash = (uiHash * 65599u) + str[10];
    return uiHash;
} 

DunForceInline unsigned int getStaticStringHash(const char (&str)[13])
{
    unsigned int uiHash = str[0];
    uiHash = (uiHash * 65599u) + str[1];
    uiHash = (uiHash * 65599u) + str[2];
    uiHash = (uiHash * 65599u) + str[3];
    uiHash = (uiHash * 65599u) + str[4];
    uiHash = (uiHash * 65599u) + str[5];
    uiHash = (uiHash * 65599u) + str[6];
    uiHash = (uiHash * 65599u) + str[7];
    uiHash = (uiHash * 65599u) + str[8];
    uiHash = (uiHash * 65599u) + str[9];
    uiHash = (uiHash * 65599u) + str[10];
    uiHash = (uiHash * 65599u) + str[11];
    return uiHash;
} 

DunForceInline unsigned int getStaticStringHash(const char (&str)[14])
{
    unsigned int uiHash = str[0];
    uiHash = (uiHash * 65599u) + str[1];
    uiHash = (uiHash * 65599u) + str[2];
    uiHash = (uiHash * 65599u) + str[3];
    uiHash = (uiHash * 65599u) + str[4];
    uiHash = (uiHash * 65599u) + str[5];
    uiHash = (uiHash * 65599u) + str[6];
    uiHash = (uiHash * 65599u) + str[7];
    uiHash = (uiHash * 65599u) + str[8];
    uiHash = (uiHash * 65599u) + str[9];
    uiHash = (uiHash * 65599u) + str[10];
    uiHash = (uiHash * 65599u) + str[11];
    uiHash = (uiHash * 65599u) + str[12];
    return uiHash;
} 

DunForceInline unsigned int getStaticStringHash(const char (&str)[15])
{
    unsigned int uiHash = str[0];
    uiHash = (uiHash * 65599u) + str[1];
    uiHash = (uiHash * 65599u) + str[2];
    uiHash = (uiHash * 65599u) + str[3];
    uiHash = (uiHash * 65599u) + str[4];
    uiHash = (uiHash * 65599u) + str[5];
    uiHash = (uiHash * 65599u) + str[6];
    uiHash = (uiHash * 65599u) + str[7];
    uiHash = (uiHash * 65599u) + str[8];
    uiHash = (uiHash * 65599u) + str[9];
    uiHash = (uiHash * 65599u) + str[10];
    uiHash = (uiHash * 65599u) + str[11];
    uiHash = (uiHash * 65599u) + str[12];
    uiHash = (uiHash * 65599u) + str[13];
    return uiHash;
} 

DunForceInline unsigned int getStaticStringHash(const char (&str)[16])
{
    unsigned int uiHash = str[0];
    uiHash = (uiHash * 65599u) + str[1];
    uiHash = (uiHash * 65599u) + str[2];
    uiHash = (uiHash * 65599u) + str[3];
    uiHash = (uiHash * 65599u) + str[4];
    uiHash = (uiHash * 65599u) + str[5];
    uiHash = (uiHash * 65599u) + str[6];
    uiHash = (uiHash * 65599u) + str[7];
    uiHash = (uiHash * 65599u) + str[8];
    uiHash = (uiHash * 65599u) + str[9];
    uiHash = (uiHash * 65599u) + str[10];
    uiHash = (uiHash * 65599u) + str[11];
    uiHash = (uiHash * 65599u) + str[12];
    uiHash = (uiHash * 65599u) + str[13];
    uiHash = (uiHash * 65599u) + str[14];
    return uiHash;
} 

DunForceInline unsigned int getStaticStringHash(const char (&str)[17])
{
    unsigned int uiHash = str[0];
    uiHash = (uiHash * 65599u) + str[1];
    uiHash = (uiHash * 65599u) + str[2];
    uiHash = (uiHash * 65599u) + str[3];
    uiHash = (uiHash * 65599u) + str[4];
    uiHash = (uiHash * 65599u) + str[5];
    uiHash = (uiHash * 65599u) + str[6];
    uiHash = (uiHash * 65599u) + str[7];
    uiHash = (uiHash * 65599u) + str[8];
    uiHash = (uiHash * 65599u) + str[9];
    uiHash = (uiHash * 65599u) + str[10];
    uiHash = (uiHash * 65599u) + str[11];
    uiHash = (uiHash * 65599u) + str[12];
    uiHash = (uiHash * 65599u) + str[13];
    uiHash = (uiHash * 65599u) + str[14];
    uiHash = (uiHash * 65599u) + str[15];
    return uiHash;
} 

DunForceInline unsigned int getStaticStringHash(const char (&str)[18])
{
    unsigned int uiHash = str[0];
    uiHash = (uiHash * 65599u) + str[1];
    uiHash = (uiHash * 65599u) + str[2];
    uiHash = (uiHash * 65599u) + str[3];
    uiHash = (uiHash * 65599u) + str[4];
    uiHash = (uiHash * 65599u) + str[5];
    uiHash = (uiHash * 65599u) + str[6];
    uiHash = (uiHash * 65599u) + str[7];
    uiHash = (uiHash * 65599u) + str[8];
    uiHash = (uiHash * 65599u) + str[9];
    uiHash = (uiHash * 65599u) + str[10];
    uiHash = (uiHash * 65599u) + str[11];
    uiHash = (uiHash * 65599u) + str[12];
    uiHash = (uiHash * 65599u) + str[13];
    uiHash = (uiHash * 65599u) + str[14];
    uiHash = (uiHash * 65599u) + str[15];
    uiHash = (uiHash * 65599u) + str[16];
    return uiHash;
} 

DunForceInline unsigned int getStaticStringHash(const char (&str)[19])
{
    unsigned int uiHash = str[0];
    uiHash = (uiHash * 65599u) + str[1];
    uiHash = (uiHash * 65599u) + str[2];
    uiHash = (uiHash * 65599u) + str[3];
    uiHash = (uiHash * 65599u) + str[4];
    uiHash = (uiHash * 65599u) + str[5];
    uiHash = (uiHash * 65599u) + str[6];
    uiHash = (uiHash * 65599u) + str[7];
    uiHash = (uiHash * 65599u) + str[8];
    uiHash = (uiHash * 65599u) + str[9];
    uiHash = (uiHash * 65599u) + str[10];
    uiHash = (uiHash * 65599u) + str[11];
    uiHash = (uiHash * 65599u) + str[12];
    uiHash = (uiHash * 65599u) + str[13];
    uiHash = (uiHash * 65599u) + str[14];
    uiHash = (uiHash * 65599u) + str[15];
    uiHash = (uiHash * 65599u) + str[16];
    uiHash = (uiHash * 65599u) + str[17];
    return uiHash;
} 

DunForceInline unsigned int getStaticStringHash(const char (&str)[20])
{
    unsigned int uiHash = str[0];
    uiHash = (uiHash * 65599u) + str[1];
    uiHash = (uiHash * 65599u) + str[2];
    uiHash = (uiHash * 65599u) + str[3];
    uiHash = (uiHash * 65599u) + str[4];
    uiHash = (uiHash * 65599u) + str[5];
    uiHash = (uiHash * 65599u) + str[6];
    uiHash = (uiHash * 65599u) + str[7];
    uiHash = (uiHash * 65599u) + str[8];
    uiHash = (uiHash * 65599u) + str[9];
    uiHash = (uiHash * 65599u) + str[10];
    uiHash = (uiHash * 65599u) + str[11];
    uiHash = (uiHash * 65599u) + str[12];
    uiHash = (uiHash * 65599u) + str[13];
    uiHash = (uiHash * 65599u) + str[14];
    uiHash = (uiHash * 65599u) + str[15];
    uiHash = (uiHash * 65599u) + str[16];
    uiHash = (uiHash * 65599u) + str[17];
    uiHash = (uiHash * 65599u) + str[18];
    return uiHash;
} 

DunForceInline unsigned int getStaticStringHash(const char (&str)[21])
{
    unsigned int uiHash = str[0];
    uiHash = (uiHash * 65599u) + str[1];
    uiHash = (uiHash * 65599u) + str[2];
    uiHash = (uiHash * 65599u) + str[3];
    uiHash = (uiHash * 65599u) + str[4];
    uiHash = (uiHash * 65599u) + str[5];
    uiHash = (uiHash * 65599u) + str[6];
    uiHash = (uiHash * 65599u) + str[7];
    uiHash = (uiHash * 65599u) + str[8];
    uiHash = (uiHash * 65599u) + str[9];
    uiHash = (uiHash * 65599u) + str[10];
    uiHash = (uiHash * 65599u) + str[11];
    uiHash = (uiHash * 65599u) + str[12];
    uiHash = (uiHash * 65599u) + str[13];
    uiHash = (uiHash * 65599u) + str[14];
    uiHash = (uiHash * 65599u) + str[15];
    uiHash = (uiHash * 65599u) + str[16];
    uiHash = (uiHash * 65599u) + str[17];
    uiHash = (uiHash * 65599u) + str[18];
    uiHash = (uiHash * 65599u) + str[19];
    return uiHash;
} 

DunForceInline unsigned int getStaticStringHash(const char (&str)[22])
{
    unsigned int uiHash = str[0];

    uiHash = (uiHash * 65599u) + str[1];
    uiHash = (uiHash * 65599u) + str[2];
    uiHash = (uiHash * 65599u) + str[3];
    uiHash = (uiHash * 65599u) + str[4];
    uiHash = (uiHash * 65599u) + str[5];
    uiHash = (uiHash * 65599u) + str[6];
    uiHash = (uiHash * 65599u) + str[7];
    uiHash = (uiHash * 65599u) + str[8];
    uiHash = (uiHash * 65599u) + str[9];
    uiHash = (uiHash * 65599u) + str[10];
    uiHash = (uiHash * 65599u) + str[11];
    uiHash = (uiHash * 65599u) + str[12];
    uiHash = (uiHash * 65599u) + str[13];
    uiHash = (uiHash * 65599u) + str[14];
    uiHash = (uiHash * 65599u) + str[15];
    uiHash = (uiHash * 65599u) + str[16];
    uiHash = (uiHash * 65599u) + str[17];
    uiHash = (uiHash * 65599u) + str[18];
    uiHash = (uiHash * 65599u) + str[19];
	uiHash = (uiHash * 65599u) + str[20];

    return uiHash;
} 

DunForceInline unsigned int getStaticStringHash(const char (&str)[23])
{
    unsigned int uiHash = str[0];

    uiHash = (uiHash * 65599u) + str[1];
    uiHash = (uiHash * 65599u) + str[2];
    uiHash = (uiHash * 65599u) + str[3];
    uiHash = (uiHash * 65599u) + str[4];
    uiHash = (uiHash * 65599u) + str[5];
    uiHash = (uiHash * 65599u) + str[6];
    uiHash = (uiHash * 65599u) + str[7];
    uiHash = (uiHash * 65599u) + str[8];
    uiHash = (uiHash * 65599u) + str[9];
    uiHash = (uiHash * 65599u) + str[10];
    uiHash = (uiHash * 65599u) + str[11];
    uiHash = (uiHash * 65599u) + str[12];
    uiHash = (uiHash * 65599u) + str[13];
    uiHash = (uiHash * 65599u) + str[14];
    uiHash = (uiHash * 65599u) + str[15];
    uiHash = (uiHash * 65599u) + str[16];
    uiHash = (uiHash * 65599u) + str[17];
    uiHash = (uiHash * 65599u) + str[18];
    uiHash = (uiHash * 65599u) + str[19];
	uiHash = (uiHash * 65599u) + str[20];
	uiHash = (uiHash * 65599u) + str[21];

    return uiHash;
} 

DunForceInline unsigned int getStaticStringHash(const char (&str)[24])
{
    unsigned int uiHash = str[0];

    uiHash = (uiHash * 65599u) + str[1];
    uiHash = (uiHash * 65599u) + str[2];
    uiHash = (uiHash * 65599u) + str[3];
    uiHash = (uiHash * 65599u) + str[4];
    uiHash = (uiHash * 65599u) + str[5];
    uiHash = (uiHash * 65599u) + str[6];
    uiHash = (uiHash * 65599u) + str[7];
    uiHash = (uiHash * 65599u) + str[8];
    uiHash = (uiHash * 65599u) + str[9];
    uiHash = (uiHash * 65599u) + str[10];
    uiHash = (uiHash * 65599u) + str[11];
    uiHash = (uiHash * 65599u) + str[12];
    uiHash = (uiHash * 65599u) + str[13];
    uiHash = (uiHash * 65599u) + str[14];
    uiHash = (uiHash * 65599u) + str[15];
    uiHash = (uiHash * 65599u) + str[16];
    uiHash = (uiHash * 65599u) + str[17];
    uiHash = (uiHash * 65599u) + str[18];
    uiHash = (uiHash * 65599u) + str[19];
	uiHash = (uiHash * 65599u) + str[20];
	uiHash = (uiHash * 65599u) + str[21];
	uiHash = (uiHash * 65599u) + str[22];

    return uiHash;
} 

DunForceInline unsigned int getStaticStringHash(const char (&str)[25])
{
    unsigned int uiHash = str[0];

    uiHash = (uiHash * 65599u) + str[1];
    uiHash = (uiHash * 65599u) + str[2];
    uiHash = (uiHash * 65599u) + str[3];
    uiHash = (uiHash * 65599u) + str[4];
    uiHash = (uiHash * 65599u) + str[5];
    uiHash = (uiHash * 65599u) + str[6];
    uiHash = (uiHash * 65599u) + str[7];
    uiHash = (uiHash * 65599u) + str[8];
    uiHash = (uiHash * 65599u) + str[9];
    uiHash = (uiHash * 65599u) + str[10];
    uiHash = (uiHash * 65599u) + str[11];
    uiHash = (uiHash * 65599u) + str[12];
    uiHash = (uiHash * 65599u) + str[13];
    uiHash = (uiHash * 65599u) + str[14];
    uiHash = (uiHash * 65599u) + str[15];
    uiHash = (uiHash * 65599u) + str[16];
    uiHash = (uiHash * 65599u) + str[17];
    uiHash = (uiHash * 65599u) + str[18];
    uiHash = (uiHash * 65599u) + str[19];
	uiHash = (uiHash * 65599u) + str[20];
	uiHash = (uiHash * 65599u) + str[21];
	uiHash = (uiHash * 65599u) + str[22];
	uiHash = (uiHash * 65599u) + str[23];

    return uiHash;
} 

DunForceInline unsigned int getStaticStringHash(const char (&str)[26])
{
    unsigned int uiHash = str[0];

    uiHash = (uiHash * 65599u) + str[1];
    uiHash = (uiHash * 65599u) + str[2];
    uiHash = (uiHash * 65599u) + str[3];
    uiHash = (uiHash * 65599u) + str[4];
    uiHash = (uiHash * 65599u) + str[5];
    uiHash = (uiHash * 65599u) + str[6];
    uiHash = (uiHash * 65599u) + str[7];
    uiHash = (uiHash * 65599u) + str[8];
    uiHash = (uiHash * 65599u) + str[9];
    uiHash = (uiHash * 65599u) + str[10];
    uiHash = (uiHash * 65599u) + str[11];
    uiHash = (uiHash * 65599u) + str[12];
    uiHash = (uiHash * 65599u) + str[13];
    uiHash = (uiHash * 65599u) + str[14];
    uiHash = (uiHash * 65599u) + str[15];
    uiHash = (uiHash * 65599u) + str[16];
    uiHash = (uiHash * 65599u) + str[17];
    uiHash = (uiHash * 65599u) + str[18];
    uiHash = (uiHash * 65599u) + str[19];
	uiHash = (uiHash * 65599u) + str[20];
	uiHash = (uiHash * 65599u) + str[21];
	uiHash = (uiHash * 65599u) + str[22];
	uiHash = (uiHash * 65599u) + str[23];
	uiHash = (uiHash * 65599u) + str[24];

    return uiHash;
} 

DunForceInline unsigned int getStaticStringHash(const char (&str)[27])
{
    unsigned int uiHash = str[0];

    uiHash = (uiHash * 65599u) + str[1];
    uiHash = (uiHash * 65599u) + str[2];
    uiHash = (uiHash * 65599u) + str[3];
    uiHash = (uiHash * 65599u) + str[4];
    uiHash = (uiHash * 65599u) + str[5];
    uiHash = (uiHash * 65599u) + str[6];
    uiHash = (uiHash * 65599u) + str[7];
    uiHash = (uiHash * 65599u) + str[8];
    uiHash = (uiHash * 65599u) + str[9];
    uiHash = (uiHash * 65599u) + str[10];
    uiHash = (uiHash * 65599u) + str[11];
    uiHash = (uiHash * 65599u) + str[12];
    uiHash = (uiHash * 65599u) + str[13];
    uiHash = (uiHash * 65599u) + str[14];
    uiHash = (uiHash * 65599u) + str[15];
    uiHash = (uiHash * 65599u) + str[16];
    uiHash = (uiHash * 65599u) + str[17];
    uiHash = (uiHash * 65599u) + str[18];
    uiHash = (uiHash * 65599u) + str[19];
	uiHash = (uiHash * 65599u) + str[20];
	uiHash = (uiHash * 65599u) + str[21];
	uiHash = (uiHash * 65599u) + str[22];
	uiHash = (uiHash * 65599u) + str[23];
	uiHash = (uiHash * 65599u) + str[24];
	uiHash = (uiHash * 65599u) + str[25];

    return uiHash;
} 

DunForceInline unsigned int getStaticStringHash(const char (&str)[28])
{
    unsigned int uiHash = str[0];

    uiHash = (uiHash * 65599u) + str[1];
    uiHash = (uiHash * 65599u) + str[2];
    uiHash = (uiHash * 65599u) + str[3];
    uiHash = (uiHash * 65599u) + str[4];
    uiHash = (uiHash * 65599u) + str[5];
    uiHash = (uiHash * 65599u) + str[6];
    uiHash = (uiHash * 65599u) + str[7];
    uiHash = (uiHash * 65599u) + str[8];
    uiHash = (uiHash * 65599u) + str[9];
    uiHash = (uiHash * 65599u) + str[10];
    uiHash = (uiHash * 65599u) + str[11];
    uiHash = (uiHash * 65599u) + str[12];
    uiHash = (uiHash * 65599u) + str[13];
    uiHash = (uiHash * 65599u) + str[14];
    uiHash = (uiHash * 65599u) + str[15];
    uiHash = (uiHash * 65599u) + str[16];
    uiHash = (uiHash * 65599u) + str[17];
    uiHash = (uiHash * 65599u) + str[18];
    uiHash = (uiHash * 65599u) + str[19];
	uiHash = (uiHash * 65599u) + str[20];
	uiHash = (uiHash * 65599u) + str[21];
	uiHash = (uiHash * 65599u) + str[22];
	uiHash = (uiHash * 65599u) + str[23];
	uiHash = (uiHash * 65599u) + str[24];
	uiHash = (uiHash * 65599u) + str[25];
	uiHash = (uiHash * 65599u) + str[26];

    return uiHash;
} 

DunForceInline unsigned int getStaticStringHash(const char (&str)[29])
{
    unsigned int uiHash = str[0];

    uiHash = (uiHash * 65599u) + str[1];
    uiHash = (uiHash * 65599u) + str[2];
    uiHash = (uiHash * 65599u) + str[3];
    uiHash = (uiHash * 65599u) + str[4];
    uiHash = (uiHash * 65599u) + str[5];
    uiHash = (uiHash * 65599u) + str[6];
    uiHash = (uiHash * 65599u) + str[7];
    uiHash = (uiHash * 65599u) + str[8];
    uiHash = (uiHash * 65599u) + str[9];
    uiHash = (uiHash * 65599u) + str[10];
    uiHash = (uiHash * 65599u) + str[11];
    uiHash = (uiHash * 65599u) + str[12];
    uiHash = (uiHash * 65599u) + str[13];
    uiHash = (uiHash * 65599u) + str[14];
    uiHash = (uiHash * 65599u) + str[15];
    uiHash = (uiHash * 65599u) + str[16];
    uiHash = (uiHash * 65599u) + str[17];
    uiHash = (uiHash * 65599u) + str[18];
    uiHash = (uiHash * 65599u) + str[19];
	uiHash = (uiHash * 65599u) + str[20];
	uiHash = (uiHash * 65599u) + str[21];
	uiHash = (uiHash * 65599u) + str[22];
	uiHash = (uiHash * 65599u) + str[23];
	uiHash = (uiHash * 65599u) + str[24];
	uiHash = (uiHash * 65599u) + str[25];
	uiHash = (uiHash * 65599u) + str[26];
	uiHash = (uiHash * 65599u) + str[27];

    return uiHash;
} 

DunForceInline unsigned int getStaticStringHash(const char (&str)[30])
{
    unsigned int uiHash = str[0];

    uiHash = (uiHash * 65599u) + str[1];
    uiHash = (uiHash * 65599u) + str[2];
    uiHash = (uiHash * 65599u) + str[3];
    uiHash = (uiHash * 65599u) + str[4];
    uiHash = (uiHash * 65599u) + str[5];
    uiHash = (uiHash * 65599u) + str[6];
    uiHash = (uiHash * 65599u) + str[7];
    uiHash = (uiHash * 65599u) + str[8];
    uiHash = (uiHash * 65599u) + str[9];
    uiHash = (uiHash * 65599u) + str[10];
    uiHash = (uiHash * 65599u) + str[11];
    uiHash = (uiHash * 65599u) + str[12];
    uiHash = (uiHash * 65599u) + str[13];
    uiHash = (uiHash * 65599u) + str[14];
    uiHash = (uiHash * 65599u) + str[15];
    uiHash = (uiHash * 65599u) + str[16];
    uiHash = (uiHash * 65599u) + str[17];
    uiHash = (uiHash * 65599u) + str[18];
    uiHash = (uiHash * 65599u) + str[19];
	uiHash = (uiHash * 65599u) + str[20];
	uiHash = (uiHash * 65599u) + str[21];
	uiHash = (uiHash * 65599u) + str[22];
	uiHash = (uiHash * 65599u) + str[23];
	uiHash = (uiHash * 65599u) + str[24];
	uiHash = (uiHash * 65599u) + str[25];
	uiHash = (uiHash * 65599u) + str[26];
	uiHash = (uiHash * 65599u) + str[27];
	uiHash = (uiHash * 65599u) + str[28];

    return uiHash;
}

#endif //STATICSTRINGHASH_H
